package chongxin;
//继承和实现这个接口
public  class test1 extends Door2 implements kDoor2{
    //重写和注解
    @Override
    public void open() {
        System.out.println("开门");
    }
    @Override
    public void close() {
        System.out.println("关门");
    }
    @Override
    public void waterDoor() {
        System.out.println("防水");
    }
    @Override
    public void fangdaoDoor() {
        System.out.println("防盗");
    }
    @Override
    public void fangdanDoor() {
        System.out.println("防弹");
    }
    public static void main(String[] args) {
        //创建对象(构造方法)
         test1 th=new test1();
         //调用各自的方法(父类和接口)
         th.open();
         th.close();
         th.waterDoor();
         th.fangdanDoor();
         th.fangdaoDoor();
    }
}
